
<?php 
	//$client = new SoapClient("http://192.168.1.152:8080/ServiceRepository/helloWorldService?wsdl");
//	$name = $_POST['input'];
   //$client = new SoapClient("http://ws1.parasoft.com/glue/calculator.wsdl");

   $client = new SoapClient("http://192.168.1.152:8080/ServiceRepository/mathService?wsdl");
  /*if(empty($_POST["A"]) == false && empty($_POST["B"]) == false){	
	  $params = array('x' => $_POST["A"], 'y' => $_POST["B"]);
	  $result = $client->add($params);
	  $kq =array();
	  $kq = (get_object_vars($result));
  }*/
  if(empty($_POST["A"]) == false && empty($_POST["B"]) == false){	
  	$nameA = $_POST["A"];
	$nameB = $_POST["B"];	
	//echo $nameA." - ".$nameB;
  	$kq = $client->sum($nameA,$nameB);
	print_r($kq);
  }
?>
<html>
	<body>
    	<form action="TestServices.php" method="post">
            Input A: <input type="text" name="A" />
            Input B: <input type="text" name="B" />
            Input Name: <input type="text" name="input"/>
            <input type="submit" />
        </form>
		<?php echo "";?>
	</body>
</html> 


